package cc.armin.controller;

import cc.armin.domain.LoginForm;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.ModelAndView;



@Controller
public class LoginController {

	@RequestMapping(value = "login")
	public ModelAndView login(HttpServletRequest request, HttpServletResponse response, LoginForm command) {
		String username = command.getUsername();
		String password = command.getPassword();
		
		ModelAndView mv = new ModelAndView("/index/index", "command", "LOGIN SUCCESS, " + username);
		System.out.println("用户名：" + username + ",密码" + password);
		return mv;
	}

}
